header("content-type:image/png");出错

来源:百度知道 编辑:UC知道 时间:2024/06/17 23:47:52
Warning: Cannot modify header information - headers already sent by (output started at E:\Program Files\Apache Software Foundation\Apache2.2\htdocs\jishuqi\picture.php:2)
前方没有输出,只绘一个简单的四方框
找到问题了,没安装jd库,不过我把gd2前边的分号去掉了,但phpinfo中没有jd这一栏。

你检查一下,你的<?php之前是不是包含了空格,如果<?php没有顶格写,那么前面的空格也是输出的一部分。

picture.php这个文件的第2行有输出,
把第2行代码发出来看看。

把header("content-type:image/png");放到代码第二行前面看看

header前不能有输出